package org.zlb.manager.entity;

import javax.persistence.*;
import java.sql.Timestamp;
import java.util.Objects;

/**
 * TODO
 *
 * @author zhoulingbo
 * @date 2021/8/10 12:30
 */
@Entity
@Table(name = "org_operator_log", schema = "admin", catalog = "")
public class OrgOperatorLog {
    private long operatorLogId;
    private String operatorCode;
    private Timestamp operateTime;
    private String operateIp;
    private String operateFeature;
    private String operateDesc;

    @Id
    @Column(name = "OPERATOR_LOG_ID")
    public long getOperatorLogId() {
        return operatorLogId;
    }

    public void setOperatorLogId(long operatorLogId) {
        this.operatorLogId = operatorLogId;
    }

    @Basic
    @Column(name = "OPERATOR_CODE")
    public String getOperatorCode() {
        return operatorCode;
    }

    public void setOperatorCode(String operatorCode) {
        this.operatorCode = operatorCode;
    }

    @Basic
    @Column(name = "OPERATE_TIME")
    public Timestamp getOperateTime() {
        return operateTime;
    }

    public void setOperateTime(Timestamp operateTime) {
        this.operateTime = operateTime;
    }

    @Basic
    @Column(name = "OPERATE_IP")
    public String getOperateIp() {
        return operateIp;
    }

    public void setOperateIp(String operateIp) {
        this.operateIp = operateIp;
    }

    @Basic
    @Column(name = "OPERATE_FEATURE")
    public String getOperateFeature() {
        return operateFeature;
    }

    public void setOperateFeature(String operateFeature) {
        this.operateFeature = operateFeature;
    }

    @Basic
    @Column(name = "OPERATE_DESC")
    public String getOperateDesc() {
        return operateDesc;
    }

    public void setOperateDesc(String operateDesc) {
        this.operateDesc = operateDesc;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        OrgOperatorLog that = (OrgOperatorLog) o;
        return operatorLogId == that.operatorLogId &&
                Objects.equals(operatorCode, that.operatorCode) &&
                Objects.equals(operateTime, that.operateTime) &&
                Objects.equals(operateIp, that.operateIp) &&
                Objects.equals(operateFeature, that.operateFeature) &&
                Objects.equals(operateDesc, that.operateDesc);
    }

    @Override
    public int hashCode() {
        return Objects.hash(operatorLogId, operatorCode, operateTime, operateIp, operateFeature, operateDesc);
    }
}
